+2005-11-28 Matthias Clasen <mclasen@redhat.com>
+
+ * gtk/gtkfilechooserdefault.c (shortcuts_key_press_event_cb): Make
+ F2 work for renaming bookmarks. (#320822, Jaap A. Haitsma, patch
+ by Paolo Borelli)
+
2005-11-28 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkwindow-win32.c (gdk_window_set_urgency_hint):
+2005-11-28 Matthias Clasen <mclasen@redhat.com>
+
+ * gtk/gtkfilechooserdefault.c (shortcuts_key_press_event_cb): Make
+ F2 work for renaming bookmarks. (#320822, Jaap A. Haitsma, patch
+ by Paolo Borelli)
+
2005-11-28 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkwindow-win32.c (gdk_window_set_urgency_hint):
remove_selected_bookmarks (impl);
}
+/* Rename the selected bookmark */
static void
-rename_shortcut_cb (GtkMenuItem *item,
- GtkFileChooserDefault *impl)
+rename_selected_bookmark (GtkFileChooserDefault *impl)
{
GtkTreeIter iter;
GtkTreePath *path;
}
}
+static void
+rename_shortcut_cb (GtkMenuItem *item,
+ GtkFileChooserDefault *impl)
+{
+ rename_selected_bookmark (impl);
+}
+
/* Constructs the popup menu for the file list if needed */
static void
shortcuts_build_popup_menu (GtkFileChooserDefault *impl)
return TRUE;
}
+ if ((event->keyval == GDK_F2)
+ && (event->state & modifiers) == 0)
+ {
+ rename_selected_bookmark (impl);
+ return TRUE;
+ }
+
return FALSE;
}